package com.oa.service;

import com.oa.bean.Job;
import com.oa.bean.PageInfo;
import com.oa.dao.JobDao;

import java.util.List;

public class JobServiceImpl implements JobService{

    //获取Dao的对象
    JobDao jobDao = new JobDao();

    @Override
    public boolean insertJob(Job job) {
        return jobDao.insertJob(job);
    }

    @Override
    public boolean deleteJob(int id) {
        return jobDao.deleteJob(id);
    }

    @Override
    public boolean updateJob(Job job) {
        return jobDao.updateJob(job);
    }



    @Override
    public Job queryJobById(int jobId) {
        return jobDao.queryJobById(jobId);
    }

    @Override
    public List<Job> queryJob(PageInfo page, String name) {
        return jobDao.queryJob(page,name);
    }

    @Override
    public int queryJobCount(String name) {
        return jobDao.queryJobCount(name);
    }


    @Override
    public List<Job> queryJob() {
        return jobDao.queryJob();
    }

}
